package com.onstar.cn.weight.ptr;

import android.content.Context;
import android.util.AttributeSet;

/**
 * Created by 6335yz on 2016/7/3.
 */
public class MyPtrFrameLayout extends PtrFrameLayout {

    private MyPtrHeader myPtrHeader;

    public MyPtrFrameLayout(Context context) {
        super(context);
        initViews();
    }

    public MyPtrFrameLayout(Context context, AttributeSet attrs) {
        super(context, attrs);
        initViews();
    }

    public MyPtrFrameLayout(Context context, AttributeSet attrs, int defStyle) {
        super(context, attrs, defStyle);
        initViews();
    }

    private void initViews() {
        myPtrHeader = new MyPtrHeader(getContext());
        setHeaderView(myPtrHeader);
        addPtrUIHandler(myPtrHeader);
    }
}
